


import { dataDispose } from '../../assets/comFun'
//导航栏icon
import { DatabaseOutlined } from "@ant-design/icons"
//公告列表
import NoticeList from './Notice/NoticeList'
//log列表
import LogList from './Log/LogList';
// 车辆管理
//白名单车辆
import WhiteListList from './WhiteList/WhiteListList';
//内部车辆列表
import InteriorVehicleList from './WhiteList/InteriorVehicleList';
//临时车辆
import TemporaryVehiclesList from './WhiteList/TemporaryVehiclesList'
//进出统计
import ImportAndExportList from './ImportAndExport/ImportAndExportList'
//进出统计概览
import ImportAntExportEcharts from './ImportAndExport/ImportAntExportEcharts';
//内部车辆 -- 临时进出页面
import TemporaryEnterNext from './WhiteList/InteriorVehicleList/pages/TemporaryEnterNext';
/**
 * @description: 门禁管理 url
 * @author: xiaoxujs
 * @updata: xiaoxujs（2021-09-10） 添加备注
 */

const enumLeftAccessControl = [
    {
        key: 'notice',
        meta: {
            title: "公告管理",
            icon: <DatabaseOutlined />,
        },
        authority: 'MJGL_GG',
        path: "/noticeList",
        component: NoticeList,
    },
    {
        key: 'Log',
        meta: {
            title: "log设置",
            icon: <DatabaseOutlined />,
        },
        authority: 'MJGL_LOGO',
        path: "/LogList",
        component: LogList,
    },
    {
        key: 'vehicle',
        meta: {
            title: "车辆列表",
            icon: <DatabaseOutlined />,
        },
        authority: 'MJGL_CLLB',
        path: "/interiorVehicle/list",
        component: InteriorVehicleList,
        page: [
            {
                key: 'interiorVehicleList',
                meta: {
                    title: "内部车辆",
                    icon: <DatabaseOutlined />,
                },
                authority: 'MJGL_NB',
                path: "/interiorVehicleList",
                component: InteriorVehicleList,
            },
            {
                key: 'temporaryVehiclesList',
                meta: {
                    title: "临时车辆",
                    icon: <DatabaseOutlined />,
                },
                authority: 'MJGL_LS',
                path: "/temporaryVehicles/list",
                component: TemporaryVehiclesList,
            },
            {
                key: 'whiteListList',
                meta: {
                    title: "白名单车辆",
                    icon: <DatabaseOutlined />,
                },
                authority: 'MJGL_BMD',
                path: "/whiteList/list",
                component: WhiteListList,
            }
        ],
    },
    {
        key: 'importAndExport',
        meta: {
            title: "进出统计",
            icon: <DatabaseOutlined />,
        },
        authority: 'MJGL_JCTJ',
        path: "/importAndExportList",
        component: ImportAndExportList,        
        page: [
            {
                key: 'importAndExportList',
                meta: {
                    title: "进出统计列表",
                    icon: <DatabaseOutlined />,
                },
                authority: 'MJGL_JCLB',
                path: "/importAndExportList",
                component: ImportAndExportList,
            },
            {
                key: 'importAntExportEcharts',
                meta: {
                    title: "进出统计概览",
                    icon: <DatabaseOutlined />,
                },
                authority: 'MJGL_JCGL',
                path: "/importAntExportEcharts",
                component: ImportAntExportEcharts,
            }
        ],
    },

]

//侧边栏数据转成路由
let enumLeftAccessControlRouter = dataDispose(enumLeftAccessControl);

const enumLeftAccessControlRouterPage = [
    ...enumLeftAccessControlRouter,
    {
        path: "/temporaryEnterNext",
        component: TemporaryEnterNext
    },
    // {
    //     path: "/productionPlan/details",
    //     component: ProductionPlanDetails
    // }
]

export {
    enumLeftAccessControl,
    enumLeftAccessControlRouterPage
}
